The present invention relates to methods and apparatus for processing data within a computer network. More specifically, this invention relates to mechanisms for performing network address translation on data.
For a particular computer to communicate with other computers or web servers within a network (e.g., the Internet), the particular computer must have a unique IP address. IP protocol version 4 specifies 32 bits for the IP address, which theoretically gives about 4,294,967,296 unique IP addresses. However, there are actually only between 3.2 and 3.3 billion available IP addresses since the addresses are separated into classes and set aside for multicasting, testing and other special uses. With the explosion of the Internet, the number of IP address is not enough to give each computer a unique IP address.
One solution for addressing computers with the limited number of IP addresses is referred to as network address translation (NAT). NAT allows an intermediary device (e.g., computer, router or switch) located between the Internet network and a local network to serve as an agent for a group of local computers. A small range of IP addresses or a single IP address is assigned to represent the group of local computers. Each computer within the local group is also given a local IP address that is only used within that local group. However, the group's local IP addresses may be a duplicate of an IP address that is used within another local network. When a local computer attempts to communicate with a computer outside the local network, the intermediary device matches the local computer's local IP address to one of the intermediary device's assigned IP addresses. The intermediary device than replaces the local computer's local address with the matched assigned IP address. This matched assigned IP address is then used to communicate between the local computer and the outside computer. Thus, NAT techniques allow IP address to be duplicated across local networks.
With the advent of voice over IP (VoIP) technology and integration of voice, video traffic, and data, several user applications were developed in conformance with recommended standards, such as H.323 or SIP (Session Initiation Protocol). These protocols require embedded addresses and ports in their control path, which are later used to establish data communication between two endpoint devices. In a typical implementation, two endpoints that wish to communicate with each other will first each register their identity with a “Gatekeeper” server which has their corresponding phone numbers and port and address information. After registration of a particular endpoint, another endpoint may obtain the registered endpoint's address and port information from the Gatekeeper server using the registered endpoint's phone number. The initiating endpoint may then establish a call to the registered endpoint with the obtained address and port information. Typically, an endpoint's registration may time out at the gatekeeper server if the registered endpoint does not send “keep alive” messages to the Gatekeeper Server before a predefined time-to-live timer has expired.
When registration messages pass through a network address translation device, a binding may be created between an endpoint's local address and port and a global address and port. However, after such endpoint times out or unregisters with the Gatekeeper Server, this binding will no longer be used since a caller can no longer obtain address and port information from the Gatekeeper Server regarding the unregistered endpoint. Accordingly, the global address and port used within the binding cannot be reused by another registered endpoint (or any other type of device). This “wasted” global address and port may not be a problem in NAT devices which have a significant number of pool addresses for use in translation. However, an unused global address and port may be significant for NAT devices which use only a single global address or a small number of global address for translation.
Accordingly, there is a need for NAT mechanisms that are capable of releasing bindings between global addresses and/or ports and their corresponding local addresses and ports when an endpoint is no longer registered. More generally, there is a need for mechanisms for maintaining registration states of endpoint nodes within a network address port translation environment.